<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
    
<%@page import="gruppe7.util.Html" %>
<%@page import="gruppe7.model.User" %>
<%@page import="gruppe7.control.ServletController" %>


<%
/*
Denne side kræver at man er logget på, så der er ikke noget check for om brugeren rent faktisk
er logget på eller ej, det kan vi roligt gå ud fra */

%>

<html>
<%
Html html = new Html(); 
ServletController sc = ServletController.getInstance();
User user = sc.getSession(request, response).getUser();
%>

<% out.print(html.setHeader("Contact")); %>

<body>
<jsp:include page="main_links.jsp" />


<div id ="content">
<div id="content-left-contact">

<img src='images/contact.png' /><p>Write to us on the following address: 
<a href='mailto:tlrs-info@fantasia.com'>tlrs-info@fantasia.com</a></p><br/>
</div>
<div id='lower-content'>
<table class='contact'>
<form action='contact.do' method='post'>
<tr><td>... or fill out the online form!</td><td></td></tr>
<tr><td>Your name</td><td><input type='text' name='name' value='

<%
out.print(user.getUsername());

%>'/></td></tr>
<tr><td>Your email</td><td><input type='text' name='email' value=''/></td></tr>
<tr><td>Your message</td><td><textarea name='message' rows='8'></textarea></td></tr>
<tr><td></td><td align='right'><input class='submit' type='submit' value='send' /></td></tr>
</form>
</table>

</div>
</div>

<% out.print(html.setFooter()); %>